// Text of project Glancing written on 11/25/95 at 4:45 PM
// Beginning of file Glancing.t

// Before Script for "baseView"
// Copyright  1993, 1994 by Apple Computer, Inc.  All rights reserved.


baseView :=
    {title: "Glance Example",
     viewBounds: {top: 0, left: 0, right: 240, bottom: 336},
     viewSetupFormScript:
       func()
       begin
       	local b := GetAppParams();
       	constant kMaxWidth := 240;
       	constant kMaxHeight := 336;
       	self.viewBounds := RelBounds(b.appAreaLeft, b.appAreaTop,
       										  MIN(b.appAreaWidth, kMaxWidth),
       										  MIN(b.appAreaHeight, kMaxHeight));
       end,
     debug: "baseView",
     _proto: @157
    };


// Before Script for "pictButton"
// Copyright  1993, 1994 by Apple Computer, Inc.  All rights reserved.


pictButton :=
    {viewBounds: {left: 28, top: 122, right: 80, bottom: 144},
     buttonClickScript:
       func()
       begin
           theGlance:Toggle();
       end,
     icon: GetPictAsBits("PlaneBlink", nil),
     debug: "pictButton",
     _proto: @198
    };
AddStepForm(baseView, pictButton);




// Before Script for "theGlance"
// Copyright  1993, 1994 by Apple Computer, Inc.  All rights reserved.


theGlance :=
    {viewBounds: {left: 29, top: 157, right: 215, bottom: 207},
     text: "What's the battery state, sonny?",
     viewIdleFrequency: 1500,
     debug: "theGlance",
     _proto: @183
    };
AddStepForm(baseView, theGlance);
StepDeclare(baseView, theGlance, 'theGlance);


// Before Script for "batteryIndicator"
// Copyright  1993, 1994 by Apple Computer, Inc.  All rights reserved.


batteryIndicator :=
    {viewBounds: {left: 8, top: 32, right: 184, bottom: 48},
     debug: "batteryIndicator",
     _proto: @316
    };
AddStepForm(theGlance, batteryIndicator);






// Before Script for "title1"
// Copyright  1993, 1994 by Apple Computer, Inc.  All rights reserved.


title1 :=
    {text: "Tap button for glance...",
     viewBounds: {left: 18, top: 90, right: 226, bottom: 114},
     debug: "title1",
     _proto: @218
    };
AddStepForm(baseView, title1);




constant |layout_Glancing.t| := baseView;
// End of file Glancing.t



